package cn.lyd.org.domain;

import cn.lyd.basic.domain.BaseDomain;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * 实体类：员工
 */
@Data
public class Employee extends BaseDomain {
    //员工名称
    private String username;
    //员工电话
    private String phone;
    //员工邮箱
    private String email;
    //盐值
    private String salt;
    //密码
    private String password;
    //年龄
    private Integer age;
    //员工状态  1:启用    0：禁用
    private Integer state;
    //所属部门id
    private Long department_id;
    //登录信息Id
    private Long logininfo_id;
    //店铺id
    private Long shop_id;

    //保存上级部门的信息-包括名称
    private Department parent;
    //保存当前部门下的所有子部门
    //部门树最后一级没有数据就不显示
    @JsonInclude(JsonInclude.Include.NON_EMPTY)
    private List<Department>  children =new ArrayList<>();

    //所属角色
    private Long role_id;
}
